﻿CREATE TABLE t_user
(
	[Id] INT NOT NULL PRIMARY KEY IDENTITY,
	[Name] NVARCHAR(32) NOT NULL,
	[Gender] INT,
	[Age] INT,
	[BirthDate] Date,
	[DeptId] INT
)
go

insert into t_user(Name,Gender,Age,BirthDate,DeptId) values('huyucai',1,30,'1989-08-16',1);


CREATE TABLE t_dept
(
	[Id] INT NOT NULL PRIMARY KEY IDENTITY,
	[Name] NVARCHAR(32) NOT NULL,
	[ParentId] INT,
	[Principal] INT
)
go

insert into t_dept(Name,ParentId,Principal) values('HR',0,1);
go